<?php
namespace app\shell;

use app\model\AdminPathinfoAccountModel;
use app\service\AdminAcountService;
use app\service\AdminPathinfoService;
use share\console\CConsole;
use share\console\CLIRunner;
use share\service\MQService;
use share\utils\Helper;

class CAdminAccount extends CLIRunner{

    /**
     * 重置密码
     */
    public function reset_pass_action(){     
        $id = CConsole::prompt("input admin id to reset",1);
        $pass = substr(Helper::getUnique(),0,8);
        AdminAcountService::setAdminPassword($id,$pass);
        CConsole::print_line("reset the admin account. new pass is   ".$pass);
    }
}